<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
    body {
      margin: 0;
      display: flex;
      align-items: center;
      justify-content: space-around;
      height: 100vh;
    }
    .box{
      position: relative;
      padding: .5em 1em .35em;
      color: white;
    }
    .box::after{
      content: '';
      position: absolute;
      z-index: -1;
      top: 0;  right: 0; bottom: 0; left: 0;
      background: deepskyblue;
      transform: scaleY(1.3) perspective(.5em) rotateX(5deg);
      transform-origin: bottom;
    }
    nav{
      position: relative;
      z-index: 1;
      padding-left: 1em;
    }
    nav > a {
      position: relative;
      display: inline-block;
      margin: 0 -.3em;
      padding: .5em 1.3em .4em;
      color: #333;
      text-decoration: none;
    }
    nav > a::before{
      content: "";
      position: absolute;
      top: 0; right: 0; bottom: 0; left: 0;
      z-index: -1;
      background: #ccc;
      background-image: linear-gradient(hsla(0, 0%, 100%, .6), hsla(0, 0%, 100%, 0));
      border: 1px solid rgba(0,0,0,.4);
      border-bottom: 0;
      border-radius: .5em .5em 0 0;
      box-shadow: 0 .15em white inset;
      transform: perspective(.5em) rotateX(5deg) scale(1.1, 1.3);
      transform-origin: bottom;
    }
    nav > a.selected{
      z-index: 2;
    }
    nav > a.selected::before{
      margin-bottom: -.05em;
      background: #eee;
    }
    main{
      display: block;
      padding: 1em;
      background: #eee;
      border: .1em solid rgba(0,0,0,.4);
      border-radius: .15em;
    }
  </style>
</head>
<body>
  <div class="box">trapezoid</div>
  <div style="width: 30%;">
    <nav>
      <a href="#">Home</a>
      <a class="selected" href="#">Projects</a>
      <a href="#">About</a>
    </nav>
    <main>Content</main>
  </div>

  <script>
    const tabs = document.querySelectorAll('div nav a')
    const main = document.querySelector('main')
    for (let i = 0, len = tabs.length; i < len; i++) {
      tabs[i].addEventListener('click', function () {
        this.parentElement.querySelector('.selected').classList.remove('selected')
        this.classList.add('selected')
        main.innerHTML = this.innerHTML
      })
    }
  </script>
</body>
</html>